﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Castle.MicroKernel.Registration;
using Castle.Windsor;
using Castle.MicroKernel.SubSystems.Configuration;
using IService;

namespace Service
{
    public class ServiceInstaller : IWindsorInstaller
    {
        public void Install(IWindsorContainer container, IConfigurationStore store)
        {
            container.Register(Component.For<ITestServer>()
                      .ImplementedBy<TestServer>().LifestyleSingleton());
            //container.Register(
            //    Classes.FromThisAssembly()
            //    .BasedOn<ITestServer>()
            //    .WithServiceAllInterfaces()
            //    .LifestylePerWebRequest()
            //    );
        }
    }
}
